/**
 * 
 */
package com.ihg.hiex.entity.session.after;

import org.apache.commons.lang3.StringUtils;

import com.demo2do.core.utils.Alias;

/**
 * @author downpour
 *
 */
@Alias("SessionReportType")
public enum SessionReportType {
    
    BY_ADMIN("by admin", "admin"),
    
    BY_ASSESSOR("by assessor", "assessor"),
    
    BY_HR("by hr", "hr");

    private String description;
    
    private String alias;
    
    /**
     * 
     * @param description
     * @param alias
     * @param name
     */
    SessionReportType(String description, String alias) {
        this.description = description;
        this.alias = alias;
    }

    /**
     * 
     * @param alias
     * @return
     */
    public static SessionReportType aliasOf(String alias) {
        for(SessionReportType sessionStatus : SessionReportType.values()) {
            if(StringUtils.equalsIgnoreCase(sessionStatus.getAlias(), alias)) {
                return sessionStatus;
            }
        }
        return null;
    }
    
    /**
     * @return the description
     */
    public String getDescription() {
        return this.description;
    }
    
    /**
     * 
     * @return
     */
    public String getAlias() {
        return alias;
    }
    
}
